package uds.android.fitdroid.ui.tabs;

import uds.android.fitdroid.R;
import android.app.Activity;
import android.os.Bundle;
import android.view.KeyEvent;

public class Configuration extends Activity {
	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.configuration);
	}

	@Override
	public boolean onKeyDown(int keyCode, KeyEvent event) {
		if (keyCode == KeyEvent.KEYCODE_BACK && event.getRepeatCount() == 0) {
			if (TabTracker.getInstance().getTabHost().getCurrentTab() > 0) {
				TabTracker.getInstance().pop();
				TabTracker
						.getInstance()
						.getTabHost()
						.setCurrentTab((Integer) TabTracker.getInstance().pop());
				return true;
			}
			return false;
		}
		return false;
	}
}
